<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>案例1</title>
		<style type="text/css">
			span{
				color: red;
			}
		</style>
	</head>
	<body>
		<span>单击页面，获取坐标</span>
	</body>
</html>
<script src="../js/jquery-3.5.1.min.js" type="text/javascript" charset="utf-8"></script>
<script>
	$(function() {
		$(window).click(function(event) {
			var event = event || window.event;
			alert("坐标：  [" + event.clientX + "," + event.clientY + "]");
		})
	})
</script>
